package com.sfac.springBoot.module.test.pojo;

import com.sfac.springBoot.module.common.entity.AbstractEntity;
import com.sfac.springBoot.module.common.vo.Search;
import org.apache.commons.lang3.StringUtils;

import javax.persistence.*;
import java.util.List;

/**
 * personal demo
 **/
@Entity
@Table(name = "test_school")
public class School extends AbstractEntity {
    private String schoolName;

    @OneToMany(mappedBy = "school",cascade = CascadeType.ALL,fetch = FetchType.EAGER)
    private List<Clazz> clazzes;


    public List<Clazz> getClazzes() {
        return clazzes;
    }

    public void setClazzes(List<Clazz> clazzes) {
        this.clazzes = clazzes;
    }

    public String getSchoolName() {
        return schoolName;
    }

    public void setSchoolName(String schoolName) {
        this.schoolName = schoolName;
    }
}
